<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html><head>
	<title>Admin</title>
	<meta http-equiv="content-type" content="text/html; charset=UTF-8">
    <%= stylesheet_link_tag "all" %>
    <%= javascript_include_tag :defaults %>  
    <%= calendar_date_select_includes  %>  
</head><body>
<div id="main">
	<div id="header">
        <%= link_to image_tag('logo.jpg', :class => "logo"), :controller => "home" %>
        <h1 class="principal">ONG Educação</h1>
        <% if !session["usuario"].nil? %>
		<ul id="top-navigation">
			<li <%= (params[:controller] == 'home') ? 'class="active"' : '' %>><span><span><%=link_to "Home", :controller => "home" %></span></span></li>
			<li <%= (params[:controller] == 'escolas') ? 'class="active"' : '' %>><span><span><%=link_to "Escolas", :controller => "escolas" %></span></span></li>
			<li <%= (params[:controller] == 'alunos') ? 'class="active"' : '' %>><span><span><%=link_to "Alunos", :controller => "alunos" %></span></span></li>
			<li <%= (params[:controller] == 'voluntarios') ? 'class="active"' : '' %>><span><span><%=link_to "Voluntários", :controller => "voluntarios" %></span></span></li>
            <li <%= (params[:controller] == 'aulas') ? 'class="active"' : '' %>><span><span><%=link_to "Aulas", :controller => "aulas" %></span></span></li>
        <% if session["nivel"] == 1 %>
			<li <%= (params[:controller] == 'usuarios') ? 'class="active"' : '' %>><span><span><%=link_to "Usuários", :controller => "usuarios" %></span></span></li>
			<li <%= (params[:controller] == 'relatorios') ? 'class="active"' : '' %>><span><span><%=link_to "Relatório", :controller => "relatorios" %></span></span></li>
        <% end %>
            <li><span><span><%=link_to "Logout", :controller => "home", :action => "logout" %></span></span></li>
		</ul>
        <% end %>
	</div>
	<div id="middle">
		<div id="left-column">

		</div>
		<div id="center-column">

                <%= yield %>

		</div>
		<div id="right-column">

	  </div>
	</div>
	<div id="footer"></div>
</div>


</body></html>
